package com.bwsoft.action;

import org.apache.log4j.Logger;

import com.bwsoft.model.Message;

public class LoginAction extends BaseAction {

	private static final long serialVersionUID = 833733815845359726L;
	private static Logger log = Logger.getLogger(LoginAction.class.getClass());  


	/**
	 * 验证登录信息
	 * 
	 * @return
	 */
	public String login() {
		log.info("用户登录,用户名："+user.getAccount()+"密码："+user.getPassword());
		Message msg = userService.checkUserLogin(user);
		super.setMsg(msg);
		return msg.msgFlag ? "success" : "error";
	}


}
